<include file="Public:header" />
<section role="main" class="content-body">
    <header class="page-header"></header>
    <!-- start: page -->
    <section class="panel">
        <header class="panel-heading">
            <h2 class="panel-title">会员信息</h2></header>
        <div class="panel-body">
            <div class="row">
                <label class="col-md-2 control-label">用户名</label>
                <div class="col-md-6">
                    <input class="form-control mb-md has-value" type="text" name="currentpwd" readonly="" placeholder="" value="{$home_user_info['username']}"></div>
            </div>
            <div class="row">
                <label class="col-md-2 control-label">名字</label>
                <div class="col-md-6">
                    <input class="form-control mb-md has-value" type="text" name="newpwd" readonly="" placeholder="" value="{$home_user_info['realname']}"></div>
            </div>
            <div class="row">
                <label class="col-md-2 control-label">配套</label>
                <div class="col-md-6">
                    <input class="form-control mb-md has-value" type="text" name="ranking" readonly="" placeholder="" value="{$leavel_type[$home_user_info['leavel']]['name']}"></div>
            </div>
            <div class="clearfix" style="margin:30px 0px 25px 0px; border-bottom:1px solid #DDD;"></div>
            <h4 style="color:#cfa465;">更改帐号资料</h4>
            <div class="row">
                <form class="selects-form" method="post" id="form" autocomplete="off">
                <!-- MAIN TAB -->
                <div class="tabs">
                    <ul class="nav nav-tabs nav-justified">
                        <li class="active">
                            <a id="a-tab-1" href="#tab1" data-toggle="tab" class="text-center">个人资料</a></li>
                        <li>
                            <a id="a-tab-2" href="#tab2" data-toggle="tab" class="text-center">地址</a></li>
                        <li>
                            <a id="a-tab-3" href="#tab3" data-toggle="tab" class="text-center">银行资料</a></li>
                    </ul>
                    <div class="tab-content">
                        <!-- TAB 1 -->
                        <div id="tab1" class="tab-pane active">
                            <div class="panel-body">
                                    <div class="row col-md-10">
                                        <label class="col-md-2 control-label">名字</label>
                                        <div class="col-md-8">
                                            <input class="form-control mb-sm has-value" name="realname" id="realname" <notempty name="home_user_info['realname']">disabled</notempty> type="text" value="{$home_user_info['realname']}"></div>
                                    </div>
                                    <div class="row col-md-10">
                                        <label class="col-md-2 control-label">身份证号码</label>
                                        <div class="col-md-8">
                                            <input class="form-control mb-sm has-value" name="idcard" type="text" <notempty name="home_user_info['idcard']">disabled</notempty> value="{$home_user_info['idcard']}"></div>
                                    </div>
                                    <div class="row col-md-10">
                                        <label class="col-md-2 control-label">手机电话号码</label>
                                        <div class="col-md-8">
                                            <input class="form-control mb-sm has-value" name="phone" type="text" <notempty name="home_user_info['phone']">disabled</notempty> value="{$home_user_info['phone']}"></div>
                                    </div>
                                    <div class="row col-md-10">
                                        <label class="col-md-2 control-label">qq</label>
                                        <div class="col-md-8">
                                            <input class="form-control mb-sm has-value" name="qq" id="email" <notempty name="home_user_info['qq']">disabled</notempty> type="text" value="{$home_user_info['qq']}"></div>
                                    </div>
                                    <div class="row col-md-10">
                                        <label class="col-md-2 control-label">电子邮箱</label>
                                        <div class="col-md-8">
                                            <input class="form-control mb-sm has-value" name="email" id="email" <notempty name="home_user_info['email']">disabled</notempty> type="text" value="{$home_user_info['email']}"></div>
                                    </div>
                            </div>
                        </div>
                        <!-- TAB 2 -->
                        <div id="tab2" class="tab-pane">
                            <div class="panel-body">
                                <div class="row col-md-10">
                                    <label class="col-md-2 control-label" for="color">地址</label>
                                    <div class="col-md-8">
                                        <input class="form-control mb-sm" name="address" type="text" <notempty name="home_user_info['address']">disabled</notempty> value="{$home_user_info['address']}"></div>
                                </div>
                                <div class="row col-md-10">
                                    <label class="col-md-2 control-label" for="color">市</label>
                                    <div class="col-md-8">
                                        <input class="form-control mb-sm" name="city" type="text" <notempty name="home_user_info['city']">disabled</notempty> value="{$home_user_info['city']}"></div>
                                </div>
                                <div class="row col-md-10">
                                    <label class="col-md-2 control-label" for="color">省</label>
                                    <div class="col-md-8">
                                        <input class="form-control mb-sm" id="state" type="text" <notempty name="home_user_info['state']">disabled</notempty> name="state" value="{$home_user_info['state']}"></div>
                                </div>
                                <div class="row col-md-10">
                                    <label class="col-md-2 control-label">国家</label>
                                    <div class="col-md-8">
                                        <select class="form-control mb-sm select-input" name="country" <notempty name="home_user_info['country']">disabled</notempty>>
                                            <option value="0">请选择。。。</option>
												<volist name="country" id="vo">
													<option value="{$vo['id']}" <eq name="vo['id']" value="$home_user_info['country']"> selected</eq>>{$vo['name']}</option>
												</volist>
											</select>
                                    </div>
                                </div>
                            </div>
                        </div>
                        <div id="tab3" class="tab-pane">
                            <div class="panel-body">
                                <div class="row col-md-10">
                                    <label class="col-md-2 control-label" for="color">银行名称</label>
                                    <div class="col-md-8">
                                        <select class="form-control mb-sm" name="bank_type" id="bankname" <notempty name="user_bank['type']">disabled</notempty>>
                                            <option value="0">请选择。。。</option>
											<volist name="bank_type" id="vo">
												<option value="{$vo['id']}" <eq name="vo['id']" value="$user_bank['type']"> selected</eq>>{$vo['name']}</option>
											</volist>
										</select>
                                    </div>
                                </div>
                                <div class="row col-md-10">
                                    <label class="col-md-2 control-label" for="color">银行账号</label>
                                    <div class="col-md-8">
                                        <input class="form-control mb-sm" name="bank_card" id="acno" type="text" <notempty name="user_bank['card']">disabled</notempty> value="{$user_bank['card']}"></div>
                                </div>
                                <div class="row col-md-10">
                                    <label class="col-md-2 control-label" for="color">银行持卡人姓名</label>
                                    <div class="col-md-8">
                                        <input class="form-control mb-sm" name="bank_realname" id="realname" type="text" <notempty name="user_bank['realname']">disabled</notempty> value="{$user_bank['realname']}"></div>
                                </div>
                                <div class="row col-md-10">
                                    <label class="col-md-2 control-label" for="color">银行分行,支行</label>
                                    <div class="col-md-8">
                                        <input class="form-control mb-sm" name="bank_address" id="address" type="text" <notempty name="user_bank['address']">disabled</notempty> value="{$user_bank['address']}"></div>
                                </div>
                                <div class="row col-md-10">
                                    <label class="col-md-2 control-label" for="color">微信账号</label>
                                    <div class="col-md-8">
                                        <input class="form-control mb-sm" name="wechat" id="wechat" type="text" <notempty name="home_user_info['wechat']">disabled</notempty> value="{$home_user_info['wechat']}"></div>
                                </div>
                                <div class="row col-md-10">
                                    <label class="col-md-2 control-label" for="color">支付宝账号</label>
                                    <div class="col-md-8">
                                        <input class="form-control mb-sm" name="zhifubao" id="address" type="text" <notempty name="home_user_info['zhifubao']">disabled</notempty>  value="{$home_user_info['zhifubao']}"></div>
                                </div>
                              <!--  <div class="row col-md-10">
                                    <label class="col-md-2 control-label" for="color">BTC地址</label>
                                    <div class="col-md-8">
                                        <input class="form-control mb-sm" name="bank_address" id="btc_url" type="text" value="{$home_user_info['btc_url']}"></div>
                                </div>
                                <div class="row col-md-10">
                                    <label class="col-md-2 control-label" for="color">LTC地址</label>
                                    <div class="col-md-8">
                                        <input class="form-control mb-sm" name="bank_address" id="ltc_url" type="text" value="{$home_user_info['ltc_url']}"></div>
                                </div>-->
                            </div>
                        </div>
                    </div>
                </div>
				</form>
			</div>
        </div>
        <footer class="panel-footer">
            <div class="row">
                <div id="form-submit" class="col-xs-12">
                    <button id="submit-req" onclick="sub()" class="btn btn-lg btn-primary pull-right" style="width:25%">提交</button></div>
            </div>
        </footer>
    </section>
		<script>
		function sub(){
			$.ajax({
				 type: "POST",
				 url: "{:U('User/informationSub')}",
				 data: $("#form").serialize(),
				 dataType: "json",
				 error: function(request) {
					layer.closeAll('loading');
					layer.msg("{$Think.lang.系统繁忙请稍后再试}");
				},
				beforeSend: function() {
					var index = layer.load(1, {
					  shade: [0.1,'#fff'] 
					});
				},
				 success: function(data){
						layer.closeAll('loading');
						layer.msg(data['info']);
						if(data['status']==true){
							setTimeout(function(){self.location.href="{:U('User/information')}"},1000);
						}else{
							changeverify();
						}
					}
			});
		};
		</script>
</section>
<include file="Public:footer" />